package com.example.mapper;
import com.example.dto.UserPageQuery;
import com.example.page.IPageQuery;
import com.example.po.UserPO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import java.util.List;

@Mapper
public interface UserMapper
{
    @Select("select id,name from t_user order by id asc")
    List<UserPO> selectPage();

    @Select("select id,name from t_user order by id asc")
    List<UserPO> selectPageNew(IPageQuery pageQuery);

    @Select("select id,name from t_user where name like #{query.keyword} order by id asc")
    List<UserPO> userPage(@Param("query") UserPageQuery pageQuery);
}
